package com.xsz.entity;

import com.fasterxml.jackson.annotation.JsonIgnore;
import lombok.Getter;
import lombok.Setter;

import javax.persistence.*;
import java.util.List;
import java.util.Set;

/**
 *
 * @author Bsea
 *  技能
 *
 */
@Table(name="tb_skill")
@Entity
@Getter
@Setter
public class Skill {

    /**主键ID**/
    @Id
    @Column(length=60)
    private String id;

    /**名称**/
    @Column(length=60)
    private String name;


    @JsonIgnore
    @ManyToMany
    @JoinTable(name="TbPossitionSkill",joinColumns={@JoinColumn(name="skillId")},inverseJoinColumns={@JoinColumn(name="pid")})
    private Set<Possition> possitionList;// 一种技能，可以用于多个职位
}
